import { request } from '@/utils';
import { getRestBaseUrl } from '@/config';

// 查询列表  zhouwenkai
export const listData4ExceptionGoods = (form, page = { pageSize: 10, pageNum: 1 }) =>
  request({
    url: `${getRestBaseUrl()}/iop/priceAdjustExceptionService/listData`,
    method: 'POST',
    data: { form, page },
    timeout: 3 * 60 * 1000,
  });

// 查询所有蜂窝
export const loadListCellular = () =>
  request({
    url: `${getRestBaseUrl()}/iop/cellularService/listAll`,
    method: 'POST',
    data: null,
    timeout: 3 * 60 * 1000,
  });
// 查询商品是否限购
export const listLimit = (channelCode = null, goodsCodes = null) =>
  request({
    url: `${getRestBaseUrl()}/iop/taskService/listLimit`,
    method: 'POST',
    data: { channelCode, goodsCodes },
    timeout: 3 * 60 * 1000,
  });
//根据蜂窝编码获取竞对门店名称
export const loadCompeteStoreNames = (cellularCode = '') =>
  request({
    url: `${getRestBaseUrl()}/iop/cellularService/listCompeteStoreNames`,
    method: 'POST',
    data: { cellularCode },
    timeout: 3 * 60 * 1000,
  });
